import axios from '@/libs/api.request'
import config from '@/config'

const yurl = config.baseUrl.dev_y + 'v1/'
/**
 * 保存产品
 * @param {*} formData
 * */
export const savePro = formData => {
  return axios.request({
    url: yurl + 'product/save',
    method: 'post',
    data: formData
  })
}
/**
 * 获取产品列表
 * @param {*} formData
 */
export const getProList = formData => {
  return axios.request({
    url: yurl + 'product',
    method: 'get',
    data: formData
  })
}

export const proDelete = id => {
  return axios.request({
    url: yurl + 'product/' + id,
    method: 'delete',
    data: {}
  })
}
